#ifndef COMMON_MACRO_DEBUG_H
#define COMMON_MACRO_DEBUG_H 1

#include <assert.h>

/* NDEBUG is what assert() relies on. */
#if !defined(NDEBUG) && !defined(NDEBUGPRINT)
 #include <stdio.h>
 #include <unistd.h>
 #define debugmsg(format, args...)  fprintf(stderr, "[%5d:%s:%d]: " format, getpid(), __PRETTY_FUNCTION__, __LINE__, ##args)
#else
 #define debugmsg(format, args...) ((void)(0))
#endif

#endif
